package com.lcj.crawler;

import com.geccocrawler.gecco.annotation.Gecco;
import com.geccocrawler.gecco.annotation.HtmlField;
import com.geccocrawler.gecco.annotation.Request;
import com.geccocrawler.gecco.annotation.Text;
import com.geccocrawler.gecco.request.HttpRequest;
import com.geccocrawler.gecco.spider.HtmlBean;
import com.geccocrawler.gecco.spider.SpiderBean;

import java.util.List;

@Gecco(matchUrl = "https://www.zptong.com/jobs/jobs-list.php?page={currPage}", pipelines = { "saveZptPipeline" })
public class ZptIndexPage implements HtmlBean, SpiderBean {

    @Request
    private HttpRequest request;

    @Text
    @HtmlField(cssPath = "li.page_all")
    private String pageAll;

    @HtmlField(cssPath = "div.info-list-wrap > div.infolist-row > div.info-list-block")
    private List<ZptCompanyRecruit> zptCompanyRecruits;

    public List<ZptCompanyRecruit> getZptCompanyRecruits() {
        return zptCompanyRecruits;
    }

    public void setZptCompanyRecruits(List<ZptCompanyRecruit> zptCompanyRecruits) {
        this.zptCompanyRecruits = zptCompanyRecruits;
    }

    public HttpRequest getRequest() {
        return request;
    }

    public void setRequest(HttpRequest request) {
        this.request = request;
    }

    public String getPageAll() {
        return pageAll;
    }

    public void setPageAll(String pageAll) {
        this.pageAll = pageAll;
    }
}
